package com.basic;

import java.util.Date;

import com.frame.struts.BaseBean;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.frame.struts.ActionContext;
import com.utils.*;

/**
 * <p>
 * Title:
 * </p>
 * <p>
 * Description:
 * </p>
 * <p>
 * Copyright: Copyright (c) 2006
 * </p>
 * <p>
 * Company:
 * </p>
 * 
 * @author not attributable
 * @version 1.0
 */

public class QtxxForm extends BaseBean
{

    private String qyid = "";
    private String qyxxlx;
    private String qyxx;
    private int xh = 0;
    private String optrid = "";
    private Date optdate = new Date();
    private String remark = "";
    private String recstate = "";

    public QtxxForm()
    {
    }

    QtxxEntity ae = new QtxxEntity();

    public String addOrgnization()
    {
        HttpServletRequest request = ActionContext.getActionContext()
                                                  .getRequest();
        HttpServletResponse response = ActionContext.getActionContext()
                                                    .getResponse();
        BasicFactory factory = new BasicFactory();
        String qyid = (String) request.getSession()
                                      .getAttribute( "session_qyid" );

        factory.deleteQtxx( qyid, "zzjgsz" );
        this.setQyid( qyid );
        this.setQyxxlx( "zzjgsz" );
        try
        {
            if( factory.addQtxx( this ) )
            {
                response.sendRedirect( request.getContextPath()
                        + "/gudong/modifyOrgnization.jsp" );
            }
            else
            {
                response.sendRedirect( request.getContextPath() + "/failed.jsp" );
            }
        }
        catch( Exception e )
        {

        }

        return null;

    }
    
    public String addGljysm()
    {
        HttpServletRequest request = ActionContext.getActionContext()
                                                  .getRequest();
        HttpServletResponse response = ActionContext.getActionContext()
                                                    .getResponse();
        BasicFactory factory = new BasicFactory();
        String qyid = (String) request.getSession()
                                      .getAttribute( "session_qyid" );

        factory.deleteQtxx( qyid, "gljysm" );
        this.setQyid( qyid );
        this.setQyxxlx( "gljysm" );
        try
        {
            if( factory.addQtxx( this ) )
            {
                response.sendRedirect( request.getContextPath()
                        + "/kehuzk/modifygljysm.jsp" );
            }
            else
            {
                response.sendRedirect( request.getContextPath() + "/failed.jsp" );
            }
        }
        catch( Exception e )
        {

        }

        return null;

    }

    public String addKhjyfx()
    {
        HttpServletRequest request = ActionContext.getActionContext()
                                                  .getRequest();
        HttpServletResponse response = ActionContext.getActionContext()
                                                    .getResponse();
        BasicFactory factory = new BasicFactory();
        String qyid = (String) request.getSession()
                                      .getAttribute( "session_qyid" );

        factory.deleteQtxx( qyid, "khjyfx" );
        this.setQyid( qyid );
        this.setQyxxlx( "khjyfx" );
        try
        {
            if( factory.addQtxx( this ) )
            {
                response.sendRedirect( request.getContextPath()
                        + "/kehuzk/modifyKhjyfx.jsp" );
            }
            else
            {
                response.sendRedirect( request.getContextPath() + "/failed.jsp" );
            }
        }
        catch( Exception e )
        {

        }

        return null;

    }

    public String addShxyxx()
    {
        HttpServletRequest request = ActionContext.getActionContext()
                                                  .getRequest();
        HttpServletResponse response = ActionContext.getActionContext()
                                                    .getResponse();
        BasicFactory factory = new BasicFactory();
        String qyid = (String) request.getSession()
                                      .getAttribute( "session_qyid" );

        factory.deleteQtxx( qyid, "shxyxx" );
        this.setQyid( qyid );
        this.setQyxxlx( "shxyxx" );
        try
        {
            if( factory.addQtxx( this ) )
            {
                response.sendRedirect( request.getContextPath()
                        + "/socialcredit/modifyShxyxx.jsp" );
            }
            else
            {
                response.sendRedirect( request.getContextPath() + "/failed.jsp" );
            }
        }
        catch( Exception e )
        {

        }
        return null;
    }

    public String addGggljgxx()
    {
        HttpServletRequest request = ActionContext.getActionContext()
                                                  .getRequest();
        HttpServletResponse response = ActionContext.getActionContext()
                                                    .getResponse();
        BasicFactory factory = new BasicFactory();
        String qyid = (String) request.getSession()
                                      .getAttribute( "session_qyid" );

        factory.deleteQtxx( qyid, "gggljgxx" );
        this.setQyid( qyid );
        this.setQyxxlx( "gggljgxx" );
        try
        {
            if( factory.addQtxx( this ) )
            {
                response.sendRedirect( request.getContextPath()
                        + "/publicinfo/modifyGggljgxx.jsp" );
            }
            else
            {
                response.sendRedirect( request.getContextPath() + "/failed.jsp" );
            }
        }
        catch( Exception e )
        {

        }
        return null;
    }

    public String getQyxxlx()
    {
        return qyxxlx;
    }

    public void setQyxxlx( String qyxxlx )
    {
        this.qyxxlx = qyxxlx;
    }

    public String getQyxx()
    {
        return qyxx;
    }

    public void setQyxx( String qyxx )
    {
        this.qyxx = qyxx;
    }

    public int getXh()
    {
        return xh;
    }

    public void setXh( int xh )
    {
        this.xh = xh;
    }

    public String getOptrid()
    {
        return optrid;
    }

    public void setOptrid( String optrid )
    {
        this.optrid = optrid;
    }

    public Date getOptdate()
    {
        return optdate;
    }

    public void setOptdate( Date optdate )
    {
        this.optdate = optdate;
    }

    public String getRemark()
    {
        return remark;
    }

    public void setRemark( String remark )
    {
        this.remark = remark;
    }

    public String getRecstate()
    {
        return recstate;
    }

    public void setRecstate( String recstate )
    {
        this.recstate = recstate;
    }

    public void setQyid( String qyid )
    {
        ae.setQyid( qyid );
    }

    public String getQyid()
    {
        return ae.getQyid();
    }

}